
#ifndef __TESTAPP_H__
#define __TESTAPP_H__

#include "../SamperHelper/SampleApp.h"
#include "Renderer/LaborTextureManager.h"
using namespace std;
using namespace Labor;


//--------------------------------------------------------------------------------------
// Structures
//--------------------------------------------------------------------------------------
struct SimpleVertex
{
	D3DXVECTOR4 Pos;
	D3DXVECTOR2 Tex;
};


class  CTestApp : public CSampleApp
{
	//--------------------------------------------------------------------------------------
	// Member Variables
	//--------------------------------------------------------------------------------------
	CLIndexBuffer      *    m_pIndexBuffer;
	CLVertexBuffer     *    m_pVertexBuffer;
	D3DXMATRIX              m_World;
	D3DXMATRIX              m_View;
	D3DXMATRIX              m_Projection;
	//CLTexture          *    m_pTexture;
	LaborBaseTextureMgr         *m_pTexMgr;
	HBaseTexture            m_hTexture;
	CLCamera                m_Camera;
public:
	CTestApp();
	~CTestApp();
public :
	//bool      init( const char* appModuleFile , const wchar_t* className, const wchar_t* window_name, int width, int height);
	bool      initApp( const char* appModuleFile );

public:
	//virtual function . sub-class can override or overload this function

	virtual void            onEvent(MSG& msg);
	virtual bool            updateFrame(int passedTime);
	void initRenderData();
	void Render();

};
#endif